home *** CD-ROM | disk | FTP | other *** search
/ MacHack 2000 / MacHack 2000.toast / pc / The Hacks / Softshoe / Lisa's Mac Parts / Clipboard / Cutter.h < prev    next >
Text File  |  2000-06-23  |  609b  |  34 lines

  1. // Cutter.h
  2.  
  3. #ifndef Cutter_h
  4. #define Cutter_h
  5.  
  6. class Clipboard;
  7.  
  8. class Cutter
  9.   {
  10.     private:
  11.         Clipboard& clipboard;
  12.         bool approved;
  13.                 
  14.         // not implemented:
  15.             Cutter( const Cutter& );
  16.             void operator=( const Cutter& );
  17.         
  18.     public:
  19.         Cutter( Clipboard& );
  20.         ~Cutter();
  21.         
  22.         bool Approved() const    { return approved; }
  23.         void Approve()                { approved = true; }
  24.             /*
  25.                 If a change to a clipboard is not approved,
  26.                 the clipboard will be cleared and all 
  27.                 clipboards will be left invalid.
  28.                 Thus if an exception is thrown before approval,
  29.                 incomplete data won't be propagated.
  30.             */
  31.   };
  32.  
  33. #endif
  34.